Nevron .NET Vision
Nevron.Diagram.DataStructures Namespace / NGraphCrossingReductorBase Class / GetNumberOfCrossings Method / GetNumberOfCrossings(Int32[]) Method
The order of the vertices in the second layer.


In This Topic
    GetNumberOfCrossings(Int32[]) Method
    In This Topic
    Calculates the number of crossings between 2 layers using the edge-crossing matrix.
    Syntax
    'Declaration
     
    
    Protected Overloads Overridable Function GetNumberOfCrossings( _
       ByVal order() As System.Integer _
    ) As System.Integer
    'Usage
     
    
    Dim instance As NGraphCrossingReductorBase
    Dim order() As System.Integer
    Dim value As System.Integer
     
    value = instance.GetNumberOfCrossings(order)
    protected virtual System.int GetNumberOfCrossings( 
       System.int[] order
    )

    Parameters

    order
    The order of the vertices in the second layer.

    Return Value

    The number of edge crossings between 2 adgjacent layers.
    Remarks
    The matrix is iterated through from bottom to top. We find the index of the first cell containig true on the current row and then we increase the number of edge crossings by the number of the cells that contain true and which index is greater than the index of the first cell containing true on the current row. After that we move to the upper row and repeat the whole procedure. And so on until we reach row 1.
    Requirements

    Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

    See Also